package com.weirong.smartvault.backservice.util.common;

import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;

/**
 * 于2017/12/6由 KFEB4 创建 .
 * 反射工具
 */
public class ReflectTool {

    public static Object runMethod(Object obj,String methodName) throws NoSuchMethodException, InvocationTargetException, IllegalAccessException {
        Class tclass = obj.getClass();
        Method method = tclass.getMethod(methodName);
        return method.invoke(obj);
    }
}
